package com.guoyan.blockchain.service;

import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.guoyan.blockchain.common.response.BaseResponse;

/**
 * @author yeym
 */
public interface IMainService {
    /**
     * 数据上链
     *
     * @param jsonObject 数据
     */
    BaseResponse save(JSONObject jsonObject,Integer type);

    /**
     * 查询
     *
     * @param txId 交易id
     * @return 数据
     */
    BaseResponse query(String txId);

    BaseResponse getAll(String channelName, Integer count, String startHash);

    BaseResponse saveList(JSONArray jsonArray, Integer type);

    BaseResponse queryHis(String userName);

    BaseResponse saveAny(String key, String value);
}
